﻿using System.Windows;
using System.Windows.Controls;

namespace Module.NumberGame.Views
{
    /// <summary>
    /// Interaction logic for NumberBox
    /// </summary>
    public partial class NumberBox : UserControl
    {
        public NumberBox()
        {
            InitializeComponent();
            NumberValue = 0;
        }
        private int numberValue;
        public int NumberValue
        {
            get { return numberValue; }
            set
            {
                numberValue = value;
                //if (value == 0) Visibility = Visibility.Collapsed; else Visibility = Visibility.Visible;
                //piece.Text = (value == 0) ? " " : value.ToString();
                //BackCircle.Opacity = 0.1 * value;

            }
        }
        public int PieceLeft { get; set; }
        public int PieceTop { get; set; }
        public void SetPosition(int left, int top)
        {
            PieceLeft = left;
            PieceTop = top;
            this.Margin = new Thickness()
            {
                Left = PieceLeft * 100,
                Top = PieceTop * 100
            };
        }
    }
}
